package com.neuedu.action.web;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.neuedu.model.Laws;
import com.neuedu.service.LawsService;

@Controller
@RequestMapping("/lawsXq")
public class LawsXqAction {
	@Autowired
	private LawsService LawsService;
	
	@RequestMapping(value = "/findOne")
	public String findAll(HttpServletRequest request, HttpServletResponse response) throws Exception {
		int LawsNo = Integer.parseInt(request.getParameter("lawsNo"));

		Laws u = LawsService.findOne(LawsNo);
		request.setAttribute("laws", u);

		return "lawsXq";
		
	}
}
